<?php

namespace App\Http\Controllers\Api\V2;

use App\Models\XoTag;
use Illuminate\Http\Request;
use Log;

class TagController extends BaseController
{
    
    /**
     *
     * 获取tag列表
     * @param {Object} Request
     */
    public function index(Request $request)
    {
        $tags = XoTag::get();
		$retArr = [];
        foreach ($tags as $k => $tag) {
			$retArr[] = [
				'tag' => $tag->tag,
				'title' => $tag->title,
			];
        }
        return $this->returnSuccess($retArr);
    }
    
}
